/* 
 * Constants.java
 * 
 * Created on 2007-4-13
 * 
 * Copyright(C) 2007, by Ambow Research&Development Branch.
 * 
 * Original Author: Peng Qing
 * Contributor(s):
 * 
 * Changes 
 * -------
 * $Log: Constants.java,v $
 * Revision 1.22  2008/05/19 02:34:15  gaochao
 * *** empty log message ***
 *
 * Revision 1.21  2008/04/09 09:35:31  wanglirong
 * *** empty log message ***
 *
 * Revision 1.20  2008/04/09 08:36:59  wanglirong
 * *** empty log message ***
 *
 * Revision 1.19  2008/04/01 06:12:36  dinghuaining
 * *** empty log message ***
 *
 * Revision 1.18  2008/03/27 04:19:06  wanglirong
 * *** empty log message ***
 *
 * Revision 1.17  2008/03/14 08:41:10  dinghuaining
 * *** empty log message ***
 *
 * Revision 1.16  2008/03/03 10:20:27  dinghuaining
 * *** empty log message ***
 *
 * Revision 1.15  2008/02/29 08:38:27  dinghuaining
 * *** empty log message ***
 *
 * Revision 1.14  2008/02/29 05:46:37  dinghuaining
 * *** empty log message ***
 *
 * Revision 1.13  2008/01/18 02:55:02  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.12  2008/01/14 07:07:24  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.11  2008/01/09 03:29:35  dinghuaining
 * *** empty log message ***
 *
 * Revision 1.10  2008/01/04 10:36:33  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.9  2008/01/04 08:41:55  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.8  2008/01/04 08:40:31  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.7  2008/01/04 05:13:49  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.6  2008/01/04 01:24:19  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.5  2008/01/03 05:26:33  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.4  2008/01/03 03:10:35  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.3  2007/12/25 01:15:35  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.2  2007/12/21 05:21:42  jinchaoting
 * *** empty log message ***
 *
 * Revision 1.1  2007/12/18 02:03:23  wanglirong
 * *** empty log message ***
 *
 * Revision 1.1  2007/07/19 06:53:09  pengqing
 * *** empty log message ***
 *
 * Revision 1.15  2007/07/13 05:40:01  xiaosa
 * *** empty log message ***
 *
 * Revision 1.14  2007/07/06 06:16:25  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.13  2007/07/04 03:00:48  xiaosa
 * *** empty log message ***
 *
 * Revision 1.12  2007/06/27 08:52:33  xiaosa
 * *** empty log message ***
 *
 * Revision 1.11  2007/06/26 07:40:43  xiaosa
 * *** empty log message ***
 *
 * Revision 1.10  2007/06/26 07:19:36  xiaosa
 * *** empty log message ***
 *
 * Revision 1.9  2007/06/21 02:54:12  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.8  2007/06/18 01:13:18  xiaosa
 * *** empty log message ***
 *
 * Revision 1.7  2007/06/14 05:42:43  xiaosa
 * *** empty log message ***
 *
 * Revision 1.6  2007/06/12 01:45:13  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.5  2007/06/12 01:40:28  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.4  2007/06/10 02:49:44  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.3  2007/06/07 07:17:53  zhangrui
 * *** empty log message ***
 *
 * Revision 1.2  2007/06/06 11:03:12  zhangrui
 * *** empty log message ***
 *
 * Revision 1.1  2007/04/07 18:37:40  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.13  2007/05/28 01:31:23  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.12  2007/05/25 08:33:08  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.11  2007/05/21 05:32:50  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.10  2007/05/15 02:13:51  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.9  2007/04/26 07:32:40  yaoshunxiang
 * ���
 * TWO_WEEK_REPORT
 *
 * Revision 1.8  2007/04/26 07:11:23  yaoshunxiang
 * *** empty log message ***
 *
 * Revision 1.7  2007/04/26 07:08:21  yaoshunxiang
 * ���
 * NO_REPORT
 * �ܲð�org_id
 * �ܲ�user_id
 *
 * Revision 1.6  2007/04/26 06:51:10  yaoshunxiang
 * ��� DAY_REPORT,WEEK_REPORT
 *
 * Revision 1.5  2007/04/25 05:55:17  pengqing
 * refactor
 *
 * Revision 1.4  2007/04/25 02:09:47  pengqing
 * the code about user in session
 *
 * Revision 1.3  2007/04/17 10:00:40  pengqing
 * add user in session constants
 *
 * Revision 1.2  2007/04/13 05:46:49  pengqing
 * change properties file's position
 *
 * Revision 1.1  2007/04/13 05:45:51  pengqing
 * ʹException ��i18n ���
 *
 *
 */
package com.ambow.core.configuration;

public class Constants extends ConfigurableConstants {

	static {
		init("/conf/system.properties");
	}
	/** 服务器IP地址 */
	public final static String HOST_IP = getProperty("constant.host_ip", "localhost");
	
	/** 服务器端口号 */
	public final static String HOST_PORT = getProperty("constant.host_port", "8080");
	
	
	public final static String ERROR_BUNDLE_KEY = getProperty(
			"constant.error_bundle_key", "i18n/errors");

	public final static String USER_IN_SESSION = getProperty(
			"constant.user_in_session", "user");

	public final static String ADMIN_IN_SESSION = getProperty(
			"constant.admin_in_session", "adminTag");

	public final static String LOGIN_ACTION = getProperty(
			"constant.login_action", "login");

	public final static String LAST_URL = getProperty("constant.last_url",
			"__LAST_URL__");

	public final static String CE100_CN_NAME = getProperty(
			"constant.ce100_name", "创易教育");

	public final static String CE100_URL = getProperty("constant.ce100_url",
			"http://www.ce100.com");

	public final static String INFO_APPROVE_IMAGE = getProperty(
			"constant.info_approve_image", "/images/tu_zc.gif");

	public final static String INFO_AGAINST_IMAGE = getProperty(
			"constant.info_against_image", "/images/tu_bzc.gif");

	public final static String INFO_TOUCHED_IMAGE = getProperty(
			"constant.info_touched_image", "/images/news_xq_ws_001.gif");

	public final static String INFO_SENSELESS_IMAGE = getProperty(
			"constant.info_senseless_image", "/images/tu_wl.gif");

	public final static String INFO_ANGRY_IMAGE = getProperty(
			"constant.info_angry_image", "/images/tu_fn.gif");

	public final static String INFO_FUNNY_IMAGE = getProperty(
			"constant.info_funny_image", "/images/tu_gx.gif");

	public final static String INFO_SADNESS_IMAGE = getProperty(
			"constant.info_sadness_image", "/images/tu_ng.gif");

	public final static String INFO_NEWNESS_IMAGE = getProperty(
			"constant.info_newness_image", "/images/tu_xq.gif");

	public final static Integer INFO_APPROVE_ID = new Integer(getProperty(
			"constant.info_approve_id", "1"));

	public final static Integer INFO_AGAINST_ID = new Integer(getProperty(
			"constant.info_against_id", "2"));

	public final static Integer INFO_TOUCHED_ID = new Integer(getProperty(
			"constant.info_touched_id", "3"));

	public final static Integer INFO_SENSELESS_ID = new Integer(getProperty(
			"constant.info_senseless_id", "4"));

	public final static Integer INFO_ANGRY_ID = new Integer(getProperty(
			"constant.info_angry_id", "5"));

	public final static Integer INFO_FUNNY_ID = new Integer(getProperty(
			"constant.info_funny_id", "6"));

	public final static Integer INFO_SADNESS_ID = new Integer(getProperty(
			"constant.info_sadness_id", "7"));

	public final static Integer INFO_NEWNESS_ID = new Integer(getProperty(
			"constant.info_newness_id", "8"));

	public final static String GUEST_ID = getProperty("constant.guest_id",
			"106");

	/**
	 * 默认每页显示的数量
	 */
	public final static int DEFAULT_PAGE_SIZE = 10;

	/**
	 * 学友关系状态
	 */
	/** 学友关系 */
	public final static int FRIEND_CONFIRM = 2;

	/** 学友但未得到对方确定 */
	public final static int FRIEND_UNCONFIRM = 1;

	/** 毫无关系 */
	public final static int FRIEND_NOT = 0;

	/**
	 * 管理员帐号
	 */
	public final static String ADMIN_LONIN_ID = getProperty(
			"constant.admin.login_id", "admin");

	/**
	 * 管理员密码
	 */
	public final static String ADMIN_PASSWORD = getProperty(
			"constant.admin.password", "admin");

	public final static Integer ATTENTION_VALUE_LIMIT = new Integer(
			getProperty("constant.attention_value_limit", "100"));

	public final static String DEFAULT_PIC_PATH = getProperty(
			"constant.user.default_pic_path", "images/default");

	public final static String DEFAULT_IMAGE_FORMAT = getProperty(
			"constant.user.default_pic_format", "gif");
	/**
	 * 默认显示公告标题的字数
	 */
	public final static int DEFAULT_TITLE_SIZE = 20;
	/**
	 * 默认显示公告内容的字数
	 */
	public final static int DEFAULT_CONTENT_SIZE = 30;
	/**
	 * 默认每页显示的数量
	 */
	public final static int DEFAULT_COMMONCOLUMN_SIZE = 50;
	/**
	 * 公告管理模块ID
	 */
	public final static int PUBLICNOTIFICATION_MODULE_ID = 2;
	/**
	 * 用户管理模块ID
	 */
	public final static int USER_MODULE_ID = 3;
	/**
	 * 栏目管理模块ID
	 */
	public final static int COMMONCOLUMN_MODULE_ID = 5;
	/**
	 * 积分兑换模块ID
	 */
	public final static int PRESENT_MODULE_ID = 6;
	/**
	 * 学习卡管理模块ID
	 */
	public final static int STUDYCARD_MODULE_ID = 8;
	/**
	 * 财务管理ID
	 */
	public final static int FINANCE_MODULE_ID = 9;
	/**
	 * 订单管理ID
	 */
	public final static int ORDER_MODULE_ID =10;
	/**
	 * 会员管理模块ID
	 */
	public final static int WEBUSER_MODULE_ID = 12;
	/**
	 * 论坛管理模块ID
	 */
	public final static int BBS_MODULE_ID = 25;
	/**
	 * 博客管理模块ID
	 */
	public final static int BLOG_MODULE_ID = 26;
	/**
	 * 意见与反馈模块ID
	 */
	public final static int FEEDBACK_MODULE_ID = 27;
	/**
	 * 资源管理模块ID
	 */
	public final static int RESOURCE_MODULE_ID = 28;
	/**
	 * 习题训练营模块ID
	 */
	public final static int EXERCISE_MODULE_ID = 29;
	/**
	 * 爱问爱答模块ID
	 */
	public final static int FAQ_MODULE_ID = 30;
	/**
	 * 作文管理模块ID
	 */
	public final static int ZUOWEN_MODULE_ID = 31;
	/**
	 * 在线考场模块ID
	 */
	public final static int EXAM_MODULE_ID = 32;
	/**
	 * 专题管理模块ID
	 */
	public final static int TOPIC_MODULE_ID = 33;
	/**
	 * 评论管理模块ID
	 */
	public final static int REMARK_MODULE_ID = 34;
	
	/**
	 * 机构管理模块ID
	 */
	public final static int ORGANIZATION_MODULE_ID = 35;
	/**
	 * 机构经费管理模块ID
	 */
	public final static int ORGAN_MODULE_ID = 36;
	/**
	 * 英语writing管理模块ID
	 */
	public final static int ENGLISH_WRITING_MODULE_ID = 37;

	/**
	 * 设置返款参数
	 */
//	public final static Double COMMISSION_PARAM =  new Double (getProperty("constant.commission.param",
//	"0.6"));
	
	public final static double COMMISSION_PARAM = 0.6;
	/**
	 * 路径
	 */
	public final static String PATH = "D:/workspace/lylearnnet/webapps";
	
	//知识点树有子节点
	public final static int LEAF = 1;
	
	//知识点树无子节点
	public final static int NOTLEAF = 0;
	
	//知识点树节点可见
	public final static int OPEN = 1;
	
	//知识点树节点不可见
	public final static int CLOSE = 0;
	
	public final static String DOMAINNAME = "k12.ambow.net";
	
	//发送邮件的地址
	public final static String from = "ask@ambow.com";
	//中学大课堂管理员email地址
	public final static String adminEmail = "ping.shen@ambow.com";
	
	/** 登录拦截器中，保存SESSIONID的MAP更新时间,默认值为凌晨3点 */
	public final static int SESSION_TIMEOUT = Integer.parseInt(getProperty(
			"constant.SESSION_TIMEOUT", "3"));
}
